import axios from "@/utils/request.js";

//获取房产经纪列表
export function getAgents() {
  return axios({
    url: "/agents",
    method: "get",
  });
}
//获取房产分类列表
export function getCategories() {
  return axios({
    url: "/categories",
    method: "get",
  });
}
//获取房产经纪列表
export function getProperties(params) {
  return axios({
    url: "/properties",
    method: "get",
    params,
  });
}
//通过id获取房产详情
export function getDetailById(id) {
  return axios({
    url: `/properties/${id}`,
    method: "get",
  });
}
//搜索请求
export function searchInfo(params) {
  return axios({
    url: "/properties",
    method: "get",
    params,
  });
}
//获取关于我们的数据
export function getAbout(){
  return axios({
    url:'/pages',
    method:'get'
  })
}
